package com.example.demo.service.impl;

import com.example.demo.domain.Overtime;
import com.example.demo.domain.Vo.OvertimeVo;
import com.example.demo.mapper.OvertimeMapper;
import com.example.demo.service.IOvertimeService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class OvertimeServiceImpl implements IOvertimeService {

    @Autowired
    public OvertimeMapper overtimeMapper;

    /**
     * 查询用户
     * @param overtime
     * @return
     */
    @Override
    public List<OvertimeVo> selectOvertime(Overtime overtime) {
        return overtimeMapper.selectOvertime(overtime);
    }

    /**
     * 增加角色
     * @param overtime
     */
    @Override
    public void insertOvertime(Overtime overtime) {
        overtimeMapper.insertOvertime(overtime);
    }

    /**
     * 修改加班申请
     * @param overtime
     */
    @Override
    public void updateOvertimeById(Overtime overtime) {
        overtimeMapper.updateOvertimeById(overtime);
    }

    /**
     * 删除加班申请
     * @param overtimeId
     */
    @Override
    public void delOvertimeById(long overtimeId) {
        overtimeMapper.delOvertimeById(overtimeId);
    }


}
